package com.hfkh.java65;

/**
 * @Author MDD
 * @Description
 * @Version
 * @Date
 **/
public class Vehicle {

    private double speed;
    private double size;

    public void move(){

    }

    public void setSpeed(double speed){

    }

    public double speedUp(double speed){
        return this.speed + speed;
    }

    public double speedDown(double speed){
        return this.speed-speed;
    }

    public static void main(String[] args) {
        Vehicle move = new Vehicle();
        move.speed = 100;


        System.out.println("加速 = "+move.speedUp(20));
        System.out.println("减速 = "+move.speedDown(10));
    }

}
